<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2008 XBRL International. All Rights Reserved. -->
<?xml-stylesheet type="text/xsl" href="../stylesheets/functionDefinition.xsl"?>
<function
  xmlns="http://xbrl.org/2008/function" 
  xmlns:reg="http://xbrl.org/2008/registry" 
  xmlns:xhtml="http://www.w3.org/1999/xhtml" 
  xmlns:xfi="http://www.xbrl.org/2008/function/instance" 
  xmlns:xfie="http://www.xbrl.org/2008/function/instance/error" 
  xmlns:xbrli="http://www.xbrl.org/2003/instance" 
  xmlns:xlink="http://www.w3.org/1999/xlink" 
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
  xsi:schemaLocation="
  http://xbrl.org/2008/registry ../schemas/registry.xsd
  http://xbrl.org/2008/function ../schemas/function.xsd
  ">

  <lastUpdated moment="2008-05-22T00:00:00" />

  <owners>
    <reg:owner id="geoff">
       <reg:name>Geoff Shuetrim</reg:name>
       <reg:affiliation>Galexy</reg:affiliation>
       <reg:email>geoff@galexy.net</reg:email>
       <reg:assumedOwnership moment="2008-02-05T00:00:00" />
    </reg:owner>
  </owners>

  <summary>
    Returns the QName, if any, of the member reported for the dimension
    in the scenario of the supplied item.
  </summary>

  <documentation>
  </documentation>

  <signature name="xfi:fact-explicit-scenario-dimension-value">

    <input name="item" type="schema-element(xbrli:item)">
      <xhtml:p>
        The item that the dimension value is required for.
      </xhtml:p>
    </input>

    <input name="dimension" type="xs:QName">
      <xhtml:p>
        The QName of the dimension that the value is required for.
      </xhtml:p>
    </input>

    <output type="xs:QName?">
      <xhtml:p>
        Returns the QName of the value for the dimension that is reported in the scenario of the item
        and the empty sequence if the dimension is not reported in the scenario of the item
        and no default is applicable. 
        (Reports the dimension default value when applicable for scenario.).
      </xhtml:p>
    </output>
  </signature>

  <error code="xfie:invalidExplicitDimensionQName">
    <xhtml:p>
      This error MUST be thrown the dimension does not specify an 
      explicit dimension in the reference discoverable taxonomy set.
    </xhtml:p>
  </error>

  <conformanceTest xlink:type="simple" xlink:href="90301 xfi.fact-explicit-scenario-dimension-value testcase.xml"/>

  <revisions>
    <reg:revision on="2008-02-05T10:54:00" by="geoff">
      <xhtml:p>
        Created the function definition.
      </xhtml:p>
    </reg:revision>
    <reg:revision on="2008-02-27T00:00:00" by="geoff">
      <xhtml:p>
        Made the function specific to scenarios.
      </xhtml:p>
    </reg:revision>
    <reg:revision on="2008-04-15T00:00:00" by="herm">
      <xhtml:p>
        Renamed invalidSegmentDimensionForFact to invalidDimensionForFact upon advice from Fujitsu for consistency.
      </xhtml:p>
    </reg:revision>
    <reg:revision on="2008-05-22T00:00:00" by="herm">
      <xhtml:p>
        Added note and testcase that default values are reportable.
      </xhtml:p>
    </reg:revision>
    <reg:revision on="2008-11-13T00:00:00" by="geoff">
      <xhtml:p>
        Removed the xfie:invalidDimensionForFact error code because any such problems are expected to be detected
        by pre-processing validation of the instance containing the fact.
      </xhtml:p>
    </reg:revision>
  </revisions>

</function>




